#FROM tutum/lamp:latest
FROM arm64v8/wordpress:latest

# 换源
# 设置为中国国内源
#RUN sed -i 's/archive.debian.com/mirrors.aliyun.com/g' /etc/apt/sources.list
#RUN sed -i 's/security.debian.com/mirrors.aliyun.com/g' /etc/apt/sources.list

# ADD ./sources.list /etc/apt/sources.list

RUN export DEBIAN_FRONTEND=noninteractive
WORKDIR /var/www
RUN chmod 777 -R ./
RUN mv /var/www/html /var/www/wordpress
# ADD ./app.sh /

RUN apt-get update
# RUN apt -y install nano
RUN apt-get -y install git
RUN apt-get -y install python3
RUN python3 --version




#这里替换 https://github.com/username/customapp.git 地址为你自己的项目地址
RUN git clone https://gitee.com/thinkyoung/php-start.git /var/www/html
WORKDIR /var/www/html
RUN chmod 777 -R ./


# 启动apache2
#清理
RUN apt-get clean
#对外暴漏默认端口,即不指定但默认提供
EXPOSE 80
EXPOSE 443
# CMD ["/usr/sbin/apache2ctl","-D","FOREGROUND"]
ENTRYPOINT ["docker-entrypoint.sh","apache2-foreground"]
# ENTRYPOINT ["/usr/sbin/apache2ctl"]
# CMD ["apache2-foreground"]